﻿<%@ Page Title="" Language="C#" MasterPageFile="~/rightContent.Master" AutoEventWireup="true"
  EnableEventValidation="false"  CodeBehind="BankInfo.aspx.cs" Inherits="WEB.Bank.BankInfo" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="title" runat="server">
银行设置
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
    </asp:ToolkitScriptManager>
<table width="100%" >
<tr>
<td align ="center"  >
    <asp:Label ID="lb" runat="server" Text="客户名："></asp:Label>
      
          <asp:TextBox ID="tbQuery1" runat="server"  AutoPostBack="true"  Width="233px" MaxLength="50"></asp:TextBox>
                                                <asp:AutoCompleteExtender ID="AutoCompleteExtender1" runat="server" ServiceMethod="GetCustomersName"
                                                    TargetControlID="tbQuery1" MinimumPrefixLength="1" CompletionInterval="358">
                                                </asp:AutoCompleteExtender>
                                 <asp:Button ID="btnQuery1" runat="server" Text="   查  询" OnClick="btnQuery1_Click"
                                    CssClass="Submit_Query" />
</td>
    
</tr>
</table>

    <asp:GridView ID="gv" runat="server" AutoGenerateColumns="False"  
        CellPadding="4" ForeColor="Black" GridLines="Vertical"
       CssClass="distance"
        AllowPaging="True" 
        onpageindexchanging="gv_PageIndexChanging" 
        onrowcancelingedit="gv_RowCancelingEdit"
        onrowediting="gv_RowEditing" 
        onrowupdating="gv_RowUpdating" 
        onselectedindexchanging="gv_SelectedIndexChanging" 
        
        onrowdeleting="gv_RowDeleting"
         >

     <Columns>
                        <asp:TemplateField HeaderText="序号" InsertVisible="False">
                            <ItemStyle HorizontalAlign="Center" />
                            <HeaderStyle HorizontalAlign="Center" Width="5%" />
                            <ItemTemplate>
                                <%#Container.DataItemIndex+1%>
                            </ItemTemplate>
                        </asp:TemplateField>
                  <asp:TemplateField HeaderText="公司名称">
                            <ItemTemplate>
                                <asp:TextBox ID="tbCustomerName" runat="server" Text='<%# Eval("CustomerName") %>' Enabled ="false" ></asp:TextBox>
                            </ItemTemplate>
                        </asp:TemplateField>
                         <asp:TemplateField HeaderText="电话">
                            <ItemTemplate>
                                <asp:TextBox ID="tbPhone" runat="server" Text='<%# Eval("Phone") %>'  ></asp:TextBox>
                            </ItemTemplate>
                        </asp:TemplateField>
                         <asp:TemplateField HeaderText="传真">
                            <ItemTemplate>
                                <asp:TextBox ID="tbFax" runat="server" Text='<%# Eval("Fax") %>'  ></asp:TextBox>
                            </ItemTemplate>
                        </asp:TemplateField>
                         <asp:TemplateField HeaderText="银行名称">
                            <ItemTemplate>
                                <asp:TextBox ID="tbBank" runat="server" Text='<%# Eval("Bank") %>'  ></asp:TextBox>
                            </ItemTemplate>
                        </asp:TemplateField>
                         <asp:TemplateField HeaderText="账户号码">
                            <ItemTemplate>
                                <asp:TextBox ID="tbBankNo" runat="server" Text='<%# Eval("BankNo") %>'  ></asp:TextBox>
                            </ItemTemplate>
                        </asp:TemplateField>
                         <asp:TemplateField HeaderText="备注">
                            <ItemTemplate>
                                <asp:TextBox ID="tbRemarks" runat="server" Text='<%# Eval("Remarks") %>'  ></asp:TextBox>
                                
                                 <asp:HiddenField ID="hfID" runat="server" Value='<%#Eval("ID") %>' />
                           <asp:HiddenField ID="hfCID" runat="server" Value='<%#Eval("CID") %>' />
                            </ItemTemplate>
                        </asp:TemplateField>
                        
                     <asp:CommandField ShowEditButton="True" ButtonType="Button" UpdateText="保存">
                <ControlStyle CssClass="Submit_gv" />
                      </asp:CommandField> 
                        <asp:CommandField ShowSelectButton="True" ButtonType="Button" SelectText ="+"
                        
                     />  
                        <asp:CommandField ShowDeleteButton="True" ButtonType="Button"  DeleteText ="-"/>

                      
                     
                     
                        
</Columns> 
       <FooterStyle BackColor="#CCCC99" Wrap="True" />
        <PagerStyle BackColor="#F7F7DE" ForeColor="Black" HorizontalAlign="Right" BorderColor="#006600"
            Wrap="True" />
        <SelectedRowStyle BackColor="#CE5D5A" Font-Bold="True" ForeColor="White" />
        <HeaderStyle BackColor="#6B696B" Font-Bold="True" ForeColor="White" Font-Size="Small"
            Wrap="True" />
        <SortedAscendingCellStyle BackColor="#FBFBF2" />
        <SortedAscendingHeaderStyle BackColor="#848384" />
        <SortedDescendingCellStyle BackColor="#EAEAD3" />
        <SortedDescendingHeaderStyle BackColor="#575357" />
                   <PagerTemplate>
     <br />
     <asp:Label ID="lblPage" runat="Server" Text='<%# "第" +( ((GridView)Container.NamingContainer).PageIndex +1 ) +"页/共"+ (((GridView)Container.NamingContainer).PageCount) +"页" %>'></asp:Label>
     <asp:LinkButton ID="lbnFirst" runat="Server" Text="首页" Enabled='<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>' CommandName="Page" CommandArgument="First" ></asp:LinkButton>
     <asp:LinkButton ID="lbnPrev" runat="server" Text="上一页" Enabled='<%# ((GridView)Container.NamingContainer).PageIndex != 0 %>' CommandName="Page" CommandArgument="Prev" ></asp:LinkButton>
     <asp:LinkButton ID="lbnNext" runat="Server" Text="下一页" Enabled='<%# ((GridView)Container.NamingContainer).PageIndex != (((GridView)Container.NamingContainer).PageCount - 1) %>' CommandName="Page" CommandArgument="Next" ></asp:LinkButton> 
     <asp:LinkButton ID="lbnLast" runat="Server" Text="尾页"   Enabled='<%# ((GridView)Container.NamingContainer).PageIndex != (((GridView)Container.NamingContainer).PageCount - 1) %>' CommandName="Page" CommandArgument="Last" ></asp:LinkButton> 
      到第
       <asp:TextBox ID="tbinPageNum" runat="server"></asp:TextBox>
      页 
      <asp:Button ID="Button1" CommandName="go" runat="server" Text ="go"  OnClick="Button1_Click" 
     
     />
      
       <br />
</PagerTemplate>
    </asp:GridView>
    <table width ="100%">
    <tr><td align ="center" >   <asp:Label ID ="lbj" runat ="server" Text ="" ></asp:Label></td> </tr>
    
    
    </table>
</asp:Content>
